package com.atguigu.gulimall.coupon.controller;

import com.atguigu.gulimall.coupon.model.Coupon;
import com.xunqi.common.utils.R;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Arrays;

@RestController
public class CouponController {

    @RequestMapping("/findCouponList")
    public R findCouponList(){
        Coupon coupon  = new Coupon();
        coupon.setCouponName("满10减2");
        return R.ok("获取优惠券成功").put("coupons", Arrays.asList(coupon));
    }
}
